#ifndef _MY_SM3_H_
#define _MY_SM3_H_

#include <crypto/internal/hash.h>
#include <linux/init.h>
#include <linux/module.h>
#include <linux/mm.h>
#include <linux/types.h>
#include <crypto/sm3.h>
#include <crypto/sm3_base.h>
#include <linux/bitops.h>
#include <asm/byteorder.h>
#include <asm/unaligned.h>

int sm3_generic_mod_init(struct shash_alg *sm3_alg);
void sm3_generic_mod_fini(struct shash_alg *sm3_alg);

int crypto_sm3_update(struct shash_desc *desc, const u8 *data,
		      unsigned int len);

int crypto_sm3_final(struct shash_desc *desc, u8 *out);

int crypto_sm3_finup(struct shash_desc *desc, const u8 *data, unsigned int len,
		     u8 *hash);

void sm3_init_alg_data(struct shash_alg *sm3_alg, struct module *module);

#endif
